###out:src/main/java/${config.packageName?replace(".","/")}/service/${root.beanName}Service.java
package ${config.packageName}.service;

import com.alibaba.fastjson.JSON;
import ${config.packageName}.dao.${root.beanName}DAO;
import ${config.packageName}.dao.jpa.${root.beanName}Repository;
import ${config.packageName}.entity.${root.beanName};
import com.zzb.framework.role.entity.IUser;
import com.zzb.framework.common.BaseResponse;
import com.zzb.framework.common.BaseService;
import com.zzb.framework.common.FrameworkException;
import com.zzb.framework.validator.annotation.ValidatorEnabled;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
* ${root.tableComment} service类
*/
@Service
public class ${root.beanName}Service extends BaseService<${root.beanName}DAO,${root.beanName},${root.beanName}Repository> {
    private static final Logger logger = LoggerFactory.getLogger(${root.beanName}Service.class);
    @Autowired
    private ${root.beanName}DAO ${root.beanName?uncap_first}DAO;
    @Override
    public ${root.beanName}DAO getDAO() {
        return ${root.beanName?uncap_first}DAO;
    }
    /**删除${root.tableComment}*/
    public BaseResponse delete${root.beanName}(String id,IUser operate) throws ServiceException{
        //TODO
        return delete(id);
    }
    /**保存${root.tableComment}*/
    @ValidatorEnabled
    public BaseResponse<${root.beanName}> save${root.beanName}(${root.beanName} ${root.beanName?uncap_first}, IUser operator) throws ServiceException{
        logger.info("正在保存${root.tableComment}["+ JSON.toJSONString(${root.beanName?uncap_first})+"]["+JSON.toJSONString(operator)+"]");
        //TODO
        return createOrUpdate(${root.beanName?uncap_first},operator);
    }
}
